public static String generateRandomString() {
    int length = 7; // 生成字符串的长度
    StringBuilder stringBuilder = new StringBuilder();

    Random random = new Random();
    for (int i = 0; i < length; i++) {
        // 生成随机的小写字母的ASCII码值范围是97到122
        int asciiValue = random.nextInt(26) + 97;
        char randomChar = (char) asciiValue;
        stringBuilder.append(randomChar);
    }

    return stringBuilder.toString();
}
public static String generateRandomStringmath() {
    int length = 13; // 生成字符串的长度
    StringBuilder stringBuilder = new StringBuilder();

    Random random = new Random();
    for (int i = 0; i < length; i++) {
        // 随机生成数字和字母的ASCII码值范围是48到122
        int asciiValue;
        do {
            asciiValue = random.nextInt(75) + 48;
        } while ((asciiValue > 57 && asciiValue < 65) || (asciiValue > 90 && asciiValue < 97));
        char randomChar = (char) asciiValue;
        stringBuilder.append(randomChar);
    }

    return stringBuilder.toString();
}
public static String generateRandomEmail() {
    Random random = new Random();
    int length = random.nextInt(2) + 9; // 生成9或10位数字
    StringBuilder stringBuilder = new StringBuilder();

    for (int i = 0; i < length; i++) {
        int digit = random.nextInt(10); // 生成0到9的随机数字
        stringBuilder.append(digit);
    }

    stringBuilder.append("@qq.com"); // 在数字后面加上"@qq.com"

    return stringBuilder.toString();
}
